package com.biostime.qdingding.modules.qd.dao;

import java.util.List;

import org.apache.ibatis.annotations.Param;

import com.biostime.qdingding.common.mybatis.MyBatisDao;
import com.biostime.qdingding.common.persistence.CrudDao;
import com.biostime.qdingding.modules.qd.api.dto.CouponDto;
import com.biostime.qdingding.modules.qd.entity.Coupon;


/**
 * 优惠券Dao
 * @author king
 * @version 2016-02-17
 */
@MyBatisDao
public interface CouponDao extends CrudDao<Coupon> {
		public List<CouponDto> myCoupons(@Param("userId")String userId,@Param("type") String type,@Param("centerId")String centerId);
		
		public int availableNum(@Param("userId")String userId,@Param("type") String type);
		
		public Coupon selectByMemberCouponId(@Param("couponId") String couponId);
		
		public int useCoupon(@Param("couponId")String couponId,@Param("useState") String useState);

		public List<Coupon> findGiftList(Coupon coupon);
}